/*
 * ObjectsGetList.java
 *
 * Created on November 15, 2008, 5:08 PM
 *
 * To change this template, choose Tools | Template Manager
 * and open the template in the editor.
 */

package jollylengkono.skripsi.Objects.action;

import java.util.ArrayList;
import java.util.List;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import jollylengkono.skripsi.dao.ObjectsDao;
import org.apache.struts.action.Action;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.ActionMapping;

/**
 *
 * @author JollkY
 */
public class ObjectsGetList extends Action {
    
    /**
     * Creates a new instance of ObjectsGetList
     */
    public ObjectsGetList() {
    }
    
    public ActionForward execute(ActionMapping mapping, ActionForm form,
            HttpServletRequest request, HttpServletResponse response) {
        List objects = new ArrayList();
        objects = new ObjectsDao().getList();
        request.setAttribute("objects", objects);
        return mapping.findForward("success");
    }
    
}
